package com.im.chat.dao;

import com.im.chat.base.BaseMapper;
import com.im.chat.model.ChatSession;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface ChatSessionMapper extends BaseMapper<ChatSession> {

    ChatSession getChatSessionByChatId(Long chatId);
    long insertChatSession(ChatSession chatSession);
    //ChatSession getInfoByChatId(Long chatId);

    int adminCloseSession(@Param("chatId") long chatId,@Param("adminId")long adminId);
    int blackSession(@Param("chatId") long chatId,@Param("adminId")long adminId);
    int adminTopSession(@Param("chatId") long chatId,@Param("adminId")long adminId);


    ChatSession getChatSessionByMemberIdAndAdminId(@Param("memberId")long memberId,@Param("adminId")long adminId);


    List<ChatSession> selectAllMemberByAdmin(@Param("adminId")Long adminId);


}
